import {postAjax} from '@/utils/axios';
import http from "@/utils/http";
import {request} from '@/utils/axios';

/**
 * 核查抽样-数据核查列表-查询调查任务列表
 * @param params
 */
export const queryVerifyWorkList = (params?: any) => {
    return http.get('verify/work/queryVerifyWorkList');
}
/**
 * 核查抽样-数据核查列表-数据导出
 * @param params
 * @returns {*|Promise<any>}
 */
export const exportVerifyCatalog = (params?: any) => {
    return request.post('verify/work/exportVerifyCatalog', params, {
        responseType: "blob",
    });
}

/**
 * 核查抽样-数据核查列表-查询调查任务抽样次数
 * @param params
 * @returns {*|Promise<any>}
 */
export const queryWorkVerifyTimes = (params?: any) => {
    return postAjax('verify/work/queryWorkVerifyTimes', params);
}

/**
 * 核查抽样-数据核查列表-查询大类统计描述
 * @param params
 * @returns {*|Promise<any>}
 */
export const getVerifyDataCategoryInfo = (params: any = {}) => {
    return postAjax('verify/work/getVerifyDataCategoryInfo', params);
}

/**
 * 核查抽样-数据核查列表-查询抽样核查数据按类别统计
 * @param params
 * @returns {*|Promise<any>}
 */
export const selectVerifyDataStatsByCategory = (params?: any) => {
    return postAjax('verify/work/selectVerifyDataStatsByCategory', params);
}

/**
 * 核查抽样-数据核查列表-查询抽样核查数据按区划统计
 * @param params
 * @returns {*|Promise<any>}
 */
export const selectVerifyDataStatsByArea = (params?: any) => {
    return postAjax('verify/work/selectVerifyDataStatsByArea', params);
}

/**
 * 核查抽样-数据核查列表-查询抽样核查数据
 * @param params
 * @returns {*|Promise<any>}
 */
export const selectVerifyDataList = (params?: any) => {
    return postAjax('verify/work/selectVerifyDataList', params);
}

/**
 * 核查抽样-规则配置-查询二级规则模板列表
 * @param params
 */
export const querySampleRuleTemplateList = (params?: any) => {
    return http.get('verify/work/querySampleRuleTemplateList');
}

/**
 * 核查抽样-数据核查列表-数据抽样
 * @param params
 * @returns {*|Promise<any>}
 */
export const dataSample = (params?: any) => {
    return postAjax('verify/work/dataSample', params);
}

